<template>
  <div class="main">
    <div class="header">
      <div class="headericons">
        <van-icon name="setting-o"/>
      </div>
    </div>
    <div class="personal">
      <van-image class="img" round width="3rem" height="2rem" src="https://img01.yzcdn.cn/vant/cat.jpeg"/>
      <div class="personalname">{{name}}<van-icon class="qwe" name="arrow" color="#afaeae" size="20" /></div>
    </div>
  </div>
</template>

<script>
export default {
  beforeCreate() {
    let token =localStorage.getItem("shop_token")
     if(!token){
       this.$router.push('/login')
     }
  },
  data() {
    return {
      name:'undefined'
    }
  },
};
</script>

<style lang="less" scoped>
.main{
  overflow: hidden;
  background-color: rgb(240, 240, 240);
.header {
  width: 100%;
  height: 50px;
  background-color: #fff;
  line-height: 50px;
  border-bottom: 1px solid #dbdada;
  .headericons {
    margin-left: 87%;
    overflow: hidden;
  }
}
.personal{
  width: 100vw;
  display: flex;
  line-height: 95px;
  .img{
    padding: 10px;
    
  }
  .personalname{
    width: 100%;
    font-size: 18px;
    font-weight: 700;
    
    .qwe{
      margin-left: 60%;
    }
  }
}
}

</style>